Produced by Araxis Merge on 2024-03-04 14:38:52 +0000. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.
| # | Location | File | Last Modified |
|---|---|---|---|
| 1 | /Users/coca/Documents/www/Porto v4.0.2/Theme Files/Magento 2.x/Porto Theme v4.0.7/app/design/frontend/Smartwave/porto/Smartwave_Filterproducts/templates/widget | side_list.phtml | 2023-09-18 02:24:36 +0000 |
| 2 | /Users/coca/Documents/www/Porto v4.0.2/Theme Files/Magento 2.x/Porto Theme v4.0.8/app/design/frontend/Smartwave/porto/Smartwave_Filterproducts/templates/widget | side_list.phtml | 2023-09-18 02:24:36 +0000 |
| Description | Between Files 1 and 2 | |
|---|---|---|
| Text Blocks | Lines | |
| Unchanged | 1 | 366 |
| Changed | 0 | 0 |
| Inserted | 0 | 0 |
| Removed | 0 | 0 |
| Whitespace | Consecutive whitespace is treated as a single space |
|---|---|
| Character case | Differences in character case are significant |
| Line endings | Differences in line endings (CR and LF characters) are ignored |
| CR/LF characters | Not shown in the comparison detail |
| Active line-pairing rules |
No regular expressions were active.
| 1 | <?php | 1 | <?php | |||
| 2 | /** | 2 | /** | |||
| 3 | * Copyright © 2015 Magento. All rights reserved. | 3 | * Copyright © 2015 Magento. All rights reserved. | |||
| 4 | * See COPYING.txt for license details. | 4 | * See COPYING.txt for license details. | |||
| 5 | */ | 5 | */ | |||
| 6 | use Magento\Framework\App\Action\Action; | 6 | use Magento\Framework\App\Action\Action; | |||
| 7 | 7 | |||||
| 8 | // @codingStandardsIgnoreFile | 8 | // @codingStandardsIgnoreFile | |||
| 9 | ?> | 9 | ?> | |||
| 10 | <?php | 10 | <?php | |||
| 11 | /** | 11 | /** | |||
| 12 | * Product list template | 12 | * Product list template | |||
| 13 | * | 13 | * | |||
| 14 | * @var $block \Smartwave\Filterproducts\Block\ | 14 | * @var $block \Smartwave\Filterproducts\Block\ | |||
| 15 | */ | 15 | */ | |||
| 16 | ?> | 16 | ?> | |||
| 17 | <?php | 17 | <?php | |||
| 18 | if ($exist = ($block->getProductCollection() && $block->getProductCollection()->getSize())) { | 18 | if ($exist = ($block->getProductCollection() && $block->getProductCollection()->getSize())) { | |||
| 19 | $_productCollection = $block->getProductCollection()->getItems(); | 19 | $_productCollection = $block->getProductCollection()->getItems(); | |||
| 20 | $_helper = $this->helper('Magento\Catalog\Helper\Output'); | 20 | $_helper = $this->helper('Magento\Catalog\Helper\Output'); | |||
| 21 | $_imagehelper = $this->helper('Magento\Catalog\Helper\Image'); | 21 | $_imagehelper = $this->helper('Magento\Catalog\Helper\Image'); | |||
| 22 | 22 | |||||
| 23 | $_portohelper = $this->helper('Smartwave\Porto\Helper\Data'); | 23 | $_portohelper = $this->helper('Smartwave\Porto\Helper\Data'); | |||
| 24 | 24 | |||||
| 25 | $_category_config = $_portohelper->getConfig('porto_settings/category'); | 25 | $_category_config = $_portohelper->getConfig('porto_settings/category'); | |||
| 26 | $_category_grid_config = $_portohelper->getConfig('porto_settings/category_grid'); | 26 | $_category_grid_config = $_portohelper->getConfig('porto_settings/category_grid'); | |||
| 27 | $_lazyload = $this->helper('Smartwave\Porto\Helper\Data')->getConfig('porto_settings/optimization/lazyload'); | 27 | $_lazyload = $this->helper('Smartwave\Porto\Helper\Data')->getConfig('porto_settings/optimization/lazyload'); | |||
| 28 | 28 | |||||
| 29 | $aspect_ratio = $this->getData("aspect_ratio"); | 29 | $aspect_ratio = $this->getData("aspect_ratio"); | |||
| 30 | if($aspect_ratio == null) { | 30 | if($aspect_ratio == null) { | |||
| 31 | $aspect_ratio = $_category_config['aspect_ratio']; | 31 | $aspect_ratio = $_category_config['aspect_ratio']; | |||
| 32 | } | 32 | } | |||
| 33 | $image_width = $this->getData("image_width"); | 33 | $image_width = $this->getData("image_width"); | |||
| 34 | if(!$image_width) { | 34 | if(!$image_width) { | |||
| 35 | $image_width = ($_category_config['ratio_width'])?$_category_config['ratio_width']:300; | 35 | $image_width = ($_category_config['ratio_width'])?$_category_config['ratio_width']:300; | |||
| 36 | } | 36 | } | |||
| 37 | $image_height = $this->getData("image_height"); | 37 | $image_height = $this->getData("image_height"); | |||
| 38 | if($aspect_ratio) | 38 | if($aspect_ratio) | |||
| 39 | $image_height = $image_width; | 39 | $image_height = $image_width; | |||
| 40 | if(!$image_height) { | 40 | if(!$image_height) { | |||
| 41 | $image_height = ($_category_config['ratio_height'])?$_category_config['ratio_height']:300; | 41 | $image_height = ($_category_config['ratio_height'])?$_category_config['ratio_height']:300; | |||
| 42 | } | 42 | } | |||
| 43 | $show_slide_nav = 'false'; | 43 | $show_slide_nav = 'false'; | |||
| 44 | if($this->hasData("show_slide_nav")){ | 44 | if($this->hasData("show_slide_nav")){ | |||
| 45 | $show_slide_nav = $this->getData("show_slide_nav") > 0 ? 'true': 'false'; | 45 | $show_slide_nav = $this->getData("show_slide_nav") > 0 ? 'true': 'false'; | |||
| 46 | } | 46 | } | |||
| 47 | $show_slide_page = 'false'; | 47 | $show_slide_page = 'false'; | |||
| 48 | if($this->hasData("show_slide_page")) { | 48 | if($this->hasData("show_slide_page")) { | |||
| 49 | $show_slide_page = $this->getData("show_slide_page") > 0 ? 'true': 'false'; | 49 | $show_slide_page = $this->getData("show_slide_page") > 0 ? 'true': 'false'; | |||
| 50 | } | 50 | } | |||
| 51 | $enable_autoplay = 'false'; | 51 | $enable_autoplay = 'false'; | |||
| 52 | if($this->hasData("enable_autoplay")) { | 52 | if($this->hasData("enable_autoplay")) { | |||
| 53 | $enable_autoplay = $this->getData("enable_autoplay") > 0 ? 'true': 'false'; | 53 | $enable_autoplay = $this->getData("enable_autoplay") > 0 ? 'true': 'false'; | |||
| 54 | } | 54 | } | |||
| 55 | $id = $block->getData('page_var_name') . uniqid('', false); | 55 | $id = $block->getData('page_var_name') . uniqid('', false); | |||
| 56 | } | 56 | } | |||
| 57 | ?> | 57 | ?> | |||
| 58 | <?php if (!$exist): ?> | 58 | <?php if (!$exist): ?> | |||
| 59 | <div class="message info empty"><div><?php echo __('We can\'t find products matching the selection.') ?></div></div> | 59 | <div class="message info empty"><div><?php echo __('We can\'t find products matching the selection.') ?></div></div> | |||
| 60 | <?php else: ?> | 60 | <?php else: ?> | |||
| 61 | <?php | 61 | <?php | |||
| 62 | $viewMode = 'grid'; | 62 | $viewMode = 'grid'; | |||
| 63 | $image = 'category_page_grid'; | 63 | $image = 'category_page_grid'; | |||
| 64 | $hover_image = 'category_page_grid-hover'; | 64 | $hover_image = 'category_page_grid-hover'; | |||
| 65 | $showDescription = false; | 65 | $showDescription = false; | |||
| 66 | $templateType = \Magento\Catalog\Block\Product\ReviewRendererInterface::SHORT_VIEW; | 66 | $templateType = \Magento\Catalog\Block\Product\ReviewRendererInterface::SHORT_VIEW; | |||
| 67 | ?> | 67 | ?> | |||
| 68 | <div id="side_product_<?php echo $id;?>"> | 68 | <div id="side_product_<?php echo $id;?>"> | |||
| 69 | <div class="products wrapper <?php echo $viewMode; ?> small-list products-<?php echo $viewMode; ?>"> | 69 | <div class="products wrapper <?php echo $viewMode; ?> small-list products-<?php echo $viewMode; ?>"> | |||
| 70 | <?php $iterator = 0; ?> | 70 | <?php $iterator = 0; ?> | |||
| 71 | <div class="filterproducts products list items product-items owl-carousel mb-0 show-nav-title"> | 71 | <div class="filterproducts products list items product-items owl-carousel mb-0 show-nav-title"> | |||
| 72 | <?php /** @var $_product \Magento\Catalog\Model\Product */ ?> | 72 | <?php /** @var $_product \Magento\Catalog\Model\Product */ ?> | |||
| 73 | <?php foreach ($_productCollection as $_product): ?> | 73 | <?php foreach ($_productCollection as $_product): ?> | |||
| 74 | <?php if(($iterator % 3) == 0): ?> | 74 | <?php if(($iterator % 3) == 0): ?> | |||
| 75 | <div class="item"> | 75 | <div class="item"> | |||
| 76 | <?php endif; ?> | 76 | <?php endif; ?> | |||
| 77 | <?php $iterator ++; ?> | 77 | <?php $iterator ++; ?> | |||
| 78 | <div class="product product-item"> | 78 | <div class="product product-item"> | |||
| 79 | <div class="product-item-info" data-container="product-grid"> | 79 | <div class="product-item-info" data-container="product-grid"> | |||
| 80 | <?php // Product Image ?> | 80 | <?php // Product Image ?> | |||
| 81 | <a href="<?php echo $_product->getProductUrl() ?>" class="product photo product-item-photo" tabindex="-1"> | 81 | <a href="<?php echo $_product->getProductUrl() ?>" class="product photo product-item-photo" tabindex="-1"> | |||
| 82 | <?php | 82 | <?php | |||
| 83 | if($aspect_ratio) | 83 | if($aspect_ratio) | |||
| 84 | $productImage = $_imagehelper->init($_product, $image)->constrainOnly(FALSE)->keepAspectRatio(TRUE)->keepFrame(FALSE)->resize($image_width); | 84 | $productImage = $_imagehelper->init($_product, $image)->constrainOnly(FALSE)->keepAspectRatio(TRUE)->keepFrame(FALSE)->resize($image_width); | |||
| 85 | else | 85 | else | |||
| 86 | $productImage = $_imagehelper->init($_product, $image)->resize($image_width, $image_height); | 86 | $productImage = $_imagehelper->init($_product, $image)->resize($image_width, $image_height); | |||
| 87 | $productImageUrl = $productImage->getUrl(); | 87 | $productImageUrl = $productImage->getUrl(); | |||
| 88 | ?> | 88 | ?> | |||
| 89 | <img class="product-image-photo default_image <?php if(!$_lazyload): ?>porto-lazyload<?php endif;?>" <?php if(!$_lazyload): ?>data-<?php endif; ?>src="<?php echo $productImageUrl; ?>" width="<?php echo $image_width; ?>" height="<?php echo $image_height; ?>" alt="<?php //echo $productImage->getLabel();?>"/> | 89 | <img class="product-image-photo default_image <?php if(!$_lazyload): ?>porto-lazyload<?php endif;?>" <?php if(!$_lazyload): ?>data-<?php endif; ?>src="<?php echo $productImageUrl; ?>" width="<?php echo $image_width; ?>" height="<?php echo $image_height; ?>" alt="<?php //echo $productImage->getLabel();?>"/> | |||
| 90 | <?php if($_category_config['alternative_image']): ?> | 90 | <?php if($_category_config['alternative_image']): ?> | |||
| 91 | <?php | 91 | <?php | |||
| 92 | if($aspect_ratio) | 92 | if($aspect_ratio) | |||
| 93 | $productHoverImage = $_imagehelper->init($_product, $hover_image)->constrainOnly(FALSE)->keepAspectRatio(TRUE)->keepFrame(FALSE)->resize($image_width); | 93 | $productHoverImage = $_imagehelper->init($_product, $hover_image)->constrainOnly(FALSE)->keepAspectRatio(TRUE)->keepFrame(FALSE)->resize($image_width); | |||
| 94 | else | 94 | else | |||
| 95 | $productHoverImage = $_imagehelper->init($_product, $hover_image)->resize($image_width, $image_height); | 95 | $productHoverImage = $_imagehelper->init($_product, $hover_image)->resize($image_width, $image_height); | |||
| 96 | $productHoverImageUrl = $productHoverImage->getUrl(); | 96 | $productHoverImageUrl = $productHoverImage->getUrl(); | |||
| 97 | ?> | 97 | ?> | |||
| 98 | <?php if($productImageUrl != str_replace("/thumbnail/","/small_image/",$productHoverImageUrl)): ?> | 98 | <?php if($productImageUrl != str_replace("/thumbnail/","/small_image/",$productHoverImageUrl)): ?> | |||
| 99 | <img class="product-image-photo hover_image" src="<?php echo $productHoverImageUrl; ?>" alt="<?php //echo $productHoverImage->getLabel();?>"/> | 99 | <img class="product-image-photo hover_image" src="<?php echo $productHoverImageUrl; ?>" alt="<?php //echo $productHoverImage->getLabel();?>"/> | |||
| 100 | <?php endif; ?> | 100 | <?php endif; ?> | |||
| 101 | <?php endif; ?> | 101 | <?php endif; ?> | |||
| 102 | </a> | 102 | </a> | |||
| 103 | <div class="product details product-item-details"> | 103 | <div class="product details product-item-details"> | |||
| 104 | <?php | 104 | <?php | |||
| 105 | $_productNameStripped = $block->stripTags($_product->getName(), null, true); | 105 | $_productNameStripped = $block->stripTags($_product->getName(), null, true); | |||
| 106 | ?> | 106 | ?> | |||
| 107 | <a href="<?php echo $_product->getProductUrl() ?>"><?php echo $_helper->productAttribute($_product, $_product->getName(), 'name'); ?></a> | 107 | <a href="<?php echo $_product->getProductUrl() ?>"><?php echo $_helper->productAttribute($_product, $_product->getName(), 'name'); ?></a> | |||
| 108 | <?php if($_category_config['rating_star']): ?> | 108 | <?php if($_category_config['rating_star']): ?> | |||
| 109 | <?php | 109 | <?php | |||
| 110 | $review_html = $block->getReviewsSummaryHtml($_product, $templateType); | 110 | $review_html = $block->getReviewsSummaryHtml($_product, $templateType); | |||
| 111 | ?> | 111 | ?> | |||
| 112 | <?php if($review_html): ?> | 112 | <?php if($review_html): ?> | |||
| 113 | <?php echo $block->getReviewsSummaryHtml($_product, $templateType); ?> | 113 | <?php echo $block->getReviewsSummaryHtml($_product, $templateType); ?> | |||
| 114 | <?php else: ?> | 114 | <?php else: ?> | |||
| 115 | <div class="product-reviews-summary short"> | 115 | <div class="product-reviews-summary short"> | |||
| 116 | <div class="rating-summary"> | 116 | <div class="rating-summary"> | |||
| 117 | <span class="label"><span>Rating:</span></span> | 117 | <span class="label"><span>Rating:</span></span> | |||
| 118 | <div class="rating-result" title="0%"> | 118 | <div class="rating-result" title="0%"> | |||
| 119 | <span style="width:0"><span>0%</span></span> | 119 | <span style="width:0"><span>0%</span></span> | |||
| 120 | </div> | 120 | </div> | |||
| 121 | </div> | 121 | </div> | |||
| 122 | </div> | 122 | </div> | |||
| 123 | <?php endif; ?> | 123 | <?php endif; ?> | |||
| 124 | <?php endif; ?> | 124 | <?php endif; ?> | |||
| 125 | <?php if ($showDescription):?> | 125 | <?php if ($showDescription):?> | |||
| 126 | <div class="product description product-item-description"> | 126 | <div class="product description product-item-description"> | |||
| 127 | <?php echo $_helper->productAttribute($_product, $_product->getShortDescription(), 'short_description') ?> | 127 | <?php echo $_helper->productAttribute($_product, $_product->getShortDescription(), 'short_description') ?> | |||
| 128 | <a href="<?php echo $_product->getProductUrl() ?>" title="<?php echo $_productNameStripped ?>" | 128 | <a href="<?php echo $_product->getProductUrl() ?>" title="<?php echo $_productNameStripped ?>" | |||
| 129 | class="action more"><?php echo __('Learn More') ?></a> | 129 | class="action more"><?php echo __('Learn More') ?></a> | |||
| 130 | </div> | 130 | </div> | |||
| 131 | <?php endif; ?> | 131 | <?php endif; ?> | |||
| 132 | <?php if($_category_config['product_price']): ?> | 132 | <?php if($_category_config['product_price']): ?> | |||
| 133 | <?php echo $block->getProductPrice($_product) ?> | 133 | <?php echo $block->getProductPrice($_product) ?> | |||
| 134 | <?php endif; ?> | 134 | <?php endif; ?> | |||
| 135 | <?php echo $block->getProductDetailsHtml($_product); ?> | 135 | <?php echo $block->getProductDetailsHtml($_product); ?> | |||
| 136 | </div> | 136 | </div> | |||
| 137 | </div> | 137 | </div> | |||
| 138 | </div> | 138 | </div> | |||
| 139 | <?php if(($iterator % 3) == 0 || $iterator == count($_productCollection)): ?> | 139 | <?php if(($iterator % 3) == 0 || $iterator == count($_productCollection)): ?> | |||
| 140 | </div> | 140 | </div> | |||
| 141 | <?php endif; ?> | 141 | <?php endif; ?> | |||
| 142 | <?php endforeach; ?> | 142 | <?php endforeach; ?> | |||
| 143 | </div> | 143 | </div> | |||
| 144 | </div> | 144 | </div> | |||
| 145 | <script type="text/javascript"> | 145 | <script type="text/javascript"> | |||
| 146 | require([ | 146 | require([ | |||
| 147 | 'jquery', | 147 | 'jquery', | |||
| 148 | 'owlcarousel', | 148 | 'owlcarousel', | |||
| 149 | 'lazyload' | 149 | 'lazyload' | |||
| 150 | ], function ($) { | 150 | ], function ($) { | |||
| 151 | $("#side_product_<?php echo $id;?> .owl-carousel").owlCarousel({ | 151 | $("#side_product_<?php echo $id;?> .owl-carousel").owlCarousel({ | |||
| 152 | autoplay: <?php echo $enable_autoplay;?>, | 152 | autoplay: <?php echo $enable_autoplay;?>, | |||
| 153 | autoplayTimeout: 5000, | 153 | autoplayTimeout: 5000, | |||
| 154 | loop: false, | 154 | loop: false, | |||
| 155 | items: 1, | 155 | items: 1, | |||
| 156 | nav: <?php echo $show_slide_nav;?>, | 156 | nav: <?php echo $show_slide_nav;?>, | |||
| 157 | dots: <?php echo $show_slide_page;?> | 157 | dots: <?php echo $show_slide_page;?> | |||
| 158 | }); | 158 | }); | |||
| 159 | $("img.porto-lazyload:not(.porto-lazyload-loaded)").lazyload({effect:"fadeIn", effect_speed: 400 }); | 159 | $("img.porto-lazyload:not(.porto-lazyload-loaded)").lazyload({effect:"fadeIn", effect_speed: 400 }); | |||
| 160 | if ($('.porto-lazyload:not(.porto-lazyload-loaded)').closest('.owl-carousel').length) { | 160 | if ($('.porto-lazyload:not(.porto-lazyload-loaded)').closest('.owl-carousel').length) { | |||
| 161 | $('.porto-lazyload:not(.porto-lazyload-loaded)').closest('.owl-carousel').on('initialized.owl.carousel', function() { | 161 | $('.porto-lazyload:not(.porto-lazyload-loaded)').closest('.owl-carousel').on('initialized.owl.carousel', function() { | |||
| 162 | $(this).find('.porto-lazyload:not(.porto-lazyload-loaded)').trigger('appear'); | 162 | $(this).find('.porto-lazyload:not(.porto-lazyload-loaded)').trigger('appear'); | |||
| 163 | }); | 163 | }); | |||
| 164 | $('.porto-lazyload:not(.porto-lazyload-loaded)').closest('.owl-carousel').on('changed.owl.carousel', function() { | 164 | $('.porto-lazyload:not(.porto-lazyload-loaded)').closest('.owl-carousel').on('changed.owl.carousel', function() { | |||
| 165 | $(this).find('.porto-lazyload:not(.porto-lazyload-loaded)').trigger('appear'); | 165 | $(this).find('.porto-lazyload:not(.porto-lazyload-loaded)').trigger('appear'); | |||
| 166 | }); | 166 | }); | |||
| 167 | } | 167 | } | |||
| 168 | window.setTimeout(function(){ | 168 | window.setTimeout(function(){ | |||
| 169 | $('.sidebar-filterproducts').find('.porto-lazyload:not(.porto-lazyload-loaded)').trigger('appear'); | 169 | $('.sidebar-filterproducts').find('.porto-lazyload:not(.porto-lazyload-loaded)').trigger('appear'); | |||
| 170 | },500); | 170 | },500); | |||
| 171 | }); | 171 | }); | |||
| 172 | </script> | 172 | </script> | |||
| 173 | </div> | 173 | </div> | |||
| 174 | <?php if (!$block->isRedirectToCartEnabled()) : ?> | 174 | <?php if (!$block->isRedirectToCartEnabled()) : ?> | |||
| 175 | <script type="text/x-magento-init"> | 175 | <script type="text/x-magento-init"> | |||
| 176 | { | 176 | { | |||
| 177 | "[data-role=tocart-form], .form.map.checkout": { | 177 | "[data-role=tocart-form], .form.map.checkout": { | |||
| 178 | "catalogAddToCart": {} | 178 | "catalogAddToCart": {} | |||
| 179 | } | 179 | } | |||
| 180 | } | 180 | } | |||
| 181 | </script> | 181 | </script> | |||
| 182 | <?php endif; ?> | 182 | <?php endif; ?> | |||
| 183 | <?php endif; ?> | 183 | <?php endif; ?> |
Araxis Merge (but not the data content of this report) is Copyright © 1993–2019 Araxis Ltd (www.araxis.com). All rights reserved.